e521e4
@@ -85,7 +85,6 @@
   // convert from partition to table schema
   private transient Converter partTblObjectInspectorConverter;
   private transient boolean isPartitioned;
-  private transient boolean hasVC;
   private Map<MapInputPath, MapOpCtx> opCtxMap;
   private final Set<MapInputPath> listInputPaths = new HashSet<MapInputPath>();
 
@@ -353,7 +352,6 @@
private void setInspectorInput(MapInputPath inp) {
       if (tsDesc != null) {
         this.vcs = tsDesc.getVirtualCols();
         if (vcs != null && vcs.size() > 0) {
-          this.hasVC = true;
           List<String> vcNames = new ArrayList<String>(vcs.size());
           this.vcValues = new Writable[vcs.size()];
           List<ObjectInspector> vcsObjectInspectors = new ArrayList<ObjectInspector>(vcs.size());
@@ -617,7 +615,7 @@
public void process(Writable value) throws HiveException {
 
     Object row = null;
     try {
-      if (this.hasVC) {
+      if (null != this.rowWithPartAndVC) {
         this.rowWithPartAndVC[0] =
             partTblObjectInspectorConverter.convert(deserializer.deserialize(value));
         int vcPos = isPartitioned ? 2 : 1;
@@ -649,7 +647,7 @@
public void process(Writable value) throws HiveException {
     // The row has been converted to comply with table schema, irrespective of partition schema.
     // So, use tblOI (and not partOI) for forwarding
     try {
-      if (this.hasVC) {
+      if (null != this.rowWithPartAndVC) {
         forward(this.rowWithPartAndVC, this.tblRowObjectInspector);
       } else if (!isPartitioned) {
         forward(row, tblRowObjectInspector);
@@ -660,7 +658,7 @@
public void process(Writable value) throws HiveException {
       // Serialize the row and output the error message.
       String rowString;
       try {
-        if (this.hasVC) {
+        if (null != rowWithPartAndVC) {
           rowString = SerDeUtils.getJSONString(rowWithPartAndVC, tblRowObjectInspector);
         } else if (!isPartitioned) {
           rowString = SerDeUtils.getJSONString(row, tblRowObjectInspector);
